<template>
  <div>
    <!--  -->
    <!-- <h5>{{oneOrdersData}}</h5> -->
    <h3 style="text-align:left">退保列表:</h3>
    <div class="companyContent">
      <!--  -->
      <el-table :data="outOrdersData" stripe border style="width: 100%">
        <el-table-column fixed prop="_id" label="_id" width="250">
        </el-table-column>
        <!-- <el-table-column prop="订单id" label="订单id" width="250">
        </el-table-column> -->
        <el-table-column prop="oneOrdersId.flowNum" label="订单流水" width="150">
        </el-table-column>
        <el-table-column
          prop="oneOrdersId.customersId.name"
          label="客户姓名"
          width="150"
        >
        </el-table-column>
        <el-table-column
          prop="oneOrdersId.customersId.phone"
          label="客户电话"
          width="120"
        >
        </el-table-column>
        <el-table-column
          prop="oneOrdersId.productsId.classesId.classes"
          label="保险类别"
          width="120"
        >
        </el-table-column>
        <el-table-column
          prop="oneOrdersId.productsId.name"
          label="产品"
          width="120"
        >
        </el-table-column>
        <!-- <el-table-column prop="productsId.price" label="价格" width="120">
        </el-table-column> -->
        <!-- <el-table-column label="订单状态" width="120">
          <template slot-scope="scope">
            <span v-if="scope.row.state == 1">未支付</span>
            <span v-if="scope.row.state == 2">已支付</span>
            <span v-if="scope.row.state == 3">待支付</span>
          </template>
        </el-table-column> -->
        <!-- <el-table-column prop="oneOrdersId.dealTime" label="下单时间" width="120">
        </el-table-column> -->
        <!-- <el-table-column prop="saleMenId.name" label="所属销售" width="120">
        </el-table-column> -->
         <el-table-column
          prop="reasonOutOrders"
          label="退保原因"
          width="120"
        >
        </el-table-column>
         <el-table-column
          prop="outOrdersState"
          label="审核状态"
          width="120"
        >
         <template slot-scope="scope">
            <span v-if="scope.row.outOrdersState == 1" style="color:red">待审核</span>
            <span v-if="scope.row.outOrdersState == 2" style="color:green">审核通过</span>
            <span v-if="scope.row.outOrdersState == 3" style="color:red">拒绝</span>
          </template>
        </el-table-column>
        <!-- <el-table-column label="操作" width="100">
          <template slot-scope="scope">
            <el-button
              type="text"
              size="small"
              style="color:#009688;"
              @click="lookOrders(scope.row._id)"
              >查看详情</el-button
            >
          </template>
        </el-table-column> -->
      </el-table>
      <!--  -->
    </div>
    <!--  -->
    <!-- <h3 style="text-align:left">退保原因:</h3>
    <div><span></span></div> -->

   
    
     
   

  
  </div>
</template>

<script>
import { createNamespacedHelpers } from "vuex";
const { mapState, mapMutations, mapActions } = createNamespacedHelpers(
  "orders"
);
export default {
  data() {
    return {
    
    
    };
  },
  mounted() {
    // //  this.getOrdersByOrdersId({_id:localStorage.oneOrdersId});  // 所点击的订单id传过去
    this.getOutOrdersBySaleMenId({ _id: localStorage.userInforId }); // 所点击的订单id传过去
  },
  computed: {
    ...mapState(["outOrdersData"]),
  },
  methods: {
    ...mapActions(["getOutOrdersBySaleMenId", ]),
    lookOrders(_id) {
      // 传送该订单的id
      // console.log({_id});
      this.getOrdersByOrdersId({ _id });
      // 获取个人订单详情
      this.$router.push("/salesMenSystem/xOrders/xOneOrdersDetails");
    },

    
  },
};
</script>

<style></style>
